package casa.depesos.app.com.http.req;


import casa.depesos.app.com.http.HttpReq;
import casa.depesos.app.com.http.Req;
import casa.depesos.app.com.http.ReqCallback;
import casa.depesos.app.com.http.bean.AgreeBean;
import casa.depesos.app.com.http.parser.AgreeParser;
import okhttp3.FormBody;

public class GetAgreeReq implements HttpReq<AgreeBean> {

    String no;

    public GetAgreeReq(String no) {
        this.no = no;
    }

    @Override
    public boolean pass() {
        return true;
    }

    @Override
    public void req(ReqCallback<AgreeBean> callback) {//   queryProtocol
        FormBody.Builder builder = new FormBody.Builder();
        builder.add("temporaryNumber", no);
        Req.post("/app/system/retrieveServiceAgreement", getParam(), getHeader(), builder.build(), new AgreeParser(), callback, this);
    }
}
